package com.example.teachingSystem.pojo.form.semester;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import jakarta.validation.constraints.NotNull;
import lombok.Data;

import java.util.Date;

@Data
@Schema(description = "新增学期表")
public class UpdateSemesterForm {
    @Schema(description = "id")
    @NotNull(message = "学期id不能为空")
    private Long id;

    @Schema(description = "名称")
    @NotNull(message = "名称不能为空")
    private String name;

    @Schema(description = "开学时间")
    @NotNull(message = "开学时间不能为空")
    @JsonFormat(pattern="yyyy-MM-dd")
    private Date startTime;

    @Schema(description = "学期周数")
    @NotNull(message = "学期周数不能为空")
    private Integer weekNum;
}
